<!--
 @description 更多
 @fileName MoreBtn.vue
 @author zengqiongying
 @created 2022/11/08 15:02:29
-->
<template>
  <div>
    <span @click="handleClickOpen">更多</span>
    <PopPicker
      v-if="showPop"
      v-model="curSel"
      title="更多操作"
      :show.sync="showPop"
      value-name="optCode"
      label-name="buttonName"
      :list="optMenu"
      @selectChange="handleChange"
    />
  </div>
</template>

<script>
import PopPicker from '@/components/PopPicker'
export default {
  name: 'CustomerMoreBtn',
  components: { PopPicker },
  props: {
    optMenu: {
      type: Array,
      default: () => []
    }
  },
  data() {
    return {
      showPop: false,
      curSel: ''
    }
  },

  computed: {},

  created() {

  },

  methods: {
    handleClickOpen() {
      this.showPop = true
    },
    handleChange(data) {
      this.showPop = false
      this.$emit('change', this.curSel)
    }
  }
}

</script>
<style lang='less' scoped>
</style>
